<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<h3>我的车--</h3>
		
		<script>
			//js定义对象，它有很多属性
		//	var car=new Object();
			//创建一个空对象
		/*
			var car = {
				name:"AE86",
				type:"买菜用"
			};//创建对个空对象
			console.log(car);
			
			//js动态增加属性，java做不到
			car.type="玩";
			car.name="QQ"；//如果已经有name属性，会被覆盖
			car.color="白色"；
			car.price=9.9；
			console.log(car);
			*/
		   
		   var car = {};					//简写
		   			//var car;						//语法错误
		   
		   			
		   			car.name = "保时捷"
		   			console.log( car )
		   			
		   			car.type = "718 Cayman T"
		   			car.color = "红色"
		   			car.price = 641000
		   
		   
		   
		   
		</script>
		
	</body>
</html>
